<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>

<link rel="stylesheet" href="<%=request.getContextPath() %>/resource/css/top.css" type="text/css">
<%-- <script type="text/javascript" src="<%=request.getContextPath() %>/resource/js/jquery/jquery-1.8.2.js"></script> --%>
<script>

$(function(){
	var $item = $(".top #item");
	var i = 0;
	$item.each(function(index){
			$(this).click(function(){
				/*if(i != index){
					$item.eq(index).removeClass("top_item_norml");
					$item.eq(index).addClass("top_item_focus");
					$item.eq(i).removeClass("top_item_focus");
					$item.eq(i).addClass("top_item_norml");
					i = index;
				}*/
				if ($(this).html().trim() == "去买菜") {
					window.open("http://shop106228920.taobao.com/shop/view_shop.htm?spm=686.1000925.0.0.dYGcbr&mytmenu=mdianpu&utkn=g,mj2we5lnmfuwgyljmnqws1378437866361&user_number_id=1792640644&scm=1028.1.1.20001", "_blank");
					return ;
				}
				if ($(this).html().trim() == "去玩儿") {
					window.open("<%=request.getContextPath() %>/play/main", "_blank");
					return ;
				}
				if ($(this).html().trim() == "去运动") {
					window.open("<%=request.getContextPath() %>/sport/main", "_blank");
					return ;
				}
				if ($(this).html().trim() == "去散步") {
					window.open("<%=request.getContextPath() %>/walk/main", "_blank");
					return ;
				}
				/* if(i != index){
					$item.eq(index).removeClass("top_item_norml");
					$item.eq(index).addClass("top_item_focus");
					$item.eq(i).removeClass("top_item_focus");
					$item.eq(i).addClass("top_item_norml");
					i = index;
				} */
			});
			/* $(this).mouseover(function() {
				$item.eq(index).removeClass("top_item_norml");
				$item.eq(index).addClass("top_item_focus");
				$item.eq(i).removeClass("top_item_focus");
				$item.eq(i).addClass("top_item_norml");
			}); */
			
		});
	var contrlLoginNickName = setInterval(function(){
		displayLoginMessage();
	},1000);
});
function displayLoginMessage(){
	var nickName = $.cookie("userLoginNickName");
	var idNickNameHtml = $("#nickName").html("");
	if(!!nickName && idNickNameHtml != nickName){
		$("#nickName").html(nickName);
		}
	 
}
</script>
<div style="width: 1100px;height: 120px;margin: 0 auto;background: white;">
	<div style="float: left;margin-left: 118px;margin-top: 17px;">
		<a href="<%=request.getContextPath()%>/notice/info"><img alt="Logo" width="80px;" height="66px;" src="<%=request.getContextPath() %>/resource/images/pages/logo.png"></a>
	</div>
	<div style="float:left;height: 20px;width: 90px;margin-top: 52px;font-weight: bold;">|<span style="margin-left: 12px;">玉林小区</span></div>
	<div class="top">
		<div id="item" class="top_item_focus">去玩儿</div>
		<div id="item" class="top_item_norml">去买菜</div>
		<div id="item" class="top_item_norml">去运动</div>
		<div id="item" class="top_item_norml">去散步</div>
		<div  style="clear: both;"></div>
	</div>
	<div style="clear: both;"></div>
		<div id="nickName" style="font-size: 12px;margin-left: 800px;margin-top: 10px;"></div>
</div>
<%@ include file="chatLogin.jsp" %>